package com.dxy.user.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.dxy.common.pojo.Role;
import org.apache.ibatis.annotations.Select;

import java.util.List;

public interface RoleMapper extends BaseMapper<Role> {

    @Select("select * from t_role where rid in (select role_id from t_user_role where user_id = #{userId})")
    List<Role> findUserRole(Integer userId);
}
